﻿using System;
using System.Collections.Generic;
using System.Windows.Forms;
using System.Threading;

namespace 电力热故障系统
{
    static class Program
    {
        public static Entity.Login obj;
        /// <summary>
        /// 应用程序的主入口点。
        /// </summary>
        [STAThread]
        public static void Main()
        {
            bool bCreateNew;
            Mutex m = new Mutex(false, "DYYGsinoTem20080410", out bCreateNew);

            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            if (bCreateNew == true)
            {
                FrmLogin f = new FrmLogin();
                if (DialogResult.OK == f.ShowDialog())
                    Application.Run(new Form1());
            }
            else
                MessageBox.Show("此程序已经在运行", "提示", MessageBoxButtons.OK, MessageBoxIcon.Warning);
        }
    }
}